home *** CD-ROM | disk | FTP | other *** search
/ Celestin Apprentice 2 / Apprentice-Release2.iso / Source Code / C++ / Applications / Nuntius 1.2 / src / Nuntius / FileTools.h < prev    next >
Encoding:
Text File  |  1994-02-20  |  955 b   |  30 lines  |  [TEXT/MPS ]

  1. // Copyright © 1992 Peter Speck, speck@dat.ruc.dk. All rights reserved.
  2. // FileTools.h
  3.  
  4. #define __FILETOOLS__
  5.  
  6. void CheckFilenameSanity(CStr255 &filename);
  7.  
  8. Boolean FileExist(const FSSpec &spec);
  9. Boolean FileExist(TFile *file);
  10.  
  11. void MakeFilenameUnique(FSSpec &spec);
  12. void MakeFilenameUnique(TFile *file);
  13.  
  14. void ResolveAliasFile(TFile *file);
  15.  
  16. void MyRenameFile(TFile *file, const CStr255 &newname);
  17.  
  18. void FlushVols();
  19.  
  20. void GoInsideFolder(FSSpec &spec); // creates folder if non-existent
  21. void GoGroupFile(const CStr255 &groupName, FSSpec &spec);
  22.  
  23. void GetPathNameFromDirID(short vRefNum, long dirID, CStr255 &pathName);
  24.  
  25. void ChangeFileTypeAndCreator(TFile *file, OSType newCreator, OSType newType);
  26. void AskFileName(const CStr255 &prompt, const CStr255 &defaultFilename, FSSpec &spec);
  27.  
  28. void WriteASyncToFile(ParamBlockRec &pb, TFile *file, const void *p, long numBytes);
  29. void ReadASyncFromFile(ParamBlockRec &pb, TFile *file, void *p, long &numBytes);
  30.